<%@ page import="com.wus.cliente.Cliente" %>
<%@ page import="com.wus.app.Endereco" %>

<div class="fieldcontain ${hasErrors(bean: clienteInstance, field: 'processo', 'error')} required">
	<label for="processo">
		<g:message code="cliente.processo.label" default="Processo" />
		<span class="required-indicator">*</span>
	</label>
	<g:select id="processo" name="processo.id" from="${com.wus.cliente.Processo.list()}" optionKey="id" required="" value="${clienteInstance?.processo?.id}" class="many-to-one"/>
</div>

<div class="fieldcontain ${hasErrors(bean: clienteInstance, field: 'nomeEmpresa', 'error')} ">
	<label for="nomeEmpresa">
		<g:message code="cliente.nomeEmpresa.label" default="Nome Empresa" />
		
	</label>
	<g:textField name="nomeEmpresa" value="${clienteInstance?.nomeEmpresa}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: clienteInstance, field: 'cnpj', 'error')} ">
	<label for="cnpj">
		<g:message code="cliente.cnpj.label" default="Cnpj" />
		
	</label>
	<g:textField name="cnpj" value="${clienteInstance?.cnpj}"/>
</div>


<div class="fieldcontain ${hasErrors(bean: clienteInstance, field: 'contatoEmpresa', 'error')} ">
	<label for="contatoEmpresa">
		<g:message code="cliente.contatoEmpresa.label" default="Contato Empresa" />
		
	</label>
	<g:textField name="contatoEmpresa" value="${clienteInstance?.contatoEmpresa}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: clienteInstance, field: 'rg', 'error')} ">
	<label for="rg">
		<g:message code="cliente.rg.label" default="Rg" />
		
	</label>
	<g:textField name="rg" value="${clienteInstance?.rg}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: clienteInstance, field: 'cpf', 'error')} ">
	<label for="cpf">
		<g:message code="cliente.cpf.label" default="Cpf" />
		
	</label>
	<g:textField name="cpf" value="${clienteInstance?.cpf}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: clienteInstance, field: 'dataNasc', 'error')} required">
	<label for="dataNasc">
		<g:message code="cliente.dataNasc.label" default="Data Nasc" />
		<span class="required-indicator">*</span>
	</label>
	<g:datePicker name="dataNasc" precision="day"  value="${clienteInstance?.dataNasc}"  />
</div>

<div class="fieldcontain ${hasErrors(bean: clienteInstance, field: 'telefoneFixo', 'error')} ">
	<label for="telefoneFixo">
		<g:message code="cliente.telefoneFixo.label" default="Telefone Fixo" />
		
	</label>
	<g:textField name="telefoneFixo" value="${clienteInstance?.telefoneFixo}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: clienteInstance, field: 'telefoneCelular', 'error')} ">
	<label for="telefoneCelular">
		<g:message code="cliente.telefoneCelular.label" default="Telefone Celular" />
		
	</label>
	<g:textField name="telefoneCelular" value="${clienteInstance?.telefoneCelular}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: clienteInstance, field: 'email', 'error')} ">
	<label for="email">
		<g:message code="cliente.email.label" default="Email" />
		
	</label>
	<g:field type="email" name="email" value="${clienteInstance?.email}"/>
</div>

<g:render template="/endereco/form4"></g:render>

